<?php

namespace app\mall\ui\form;

use app\mall\enum\InvoiceStatusEnum;
use app\mall\enum\YesNoEnum;

/**
 * 发票管理表单
 */
class MallOrderEvaluateForm
{

    public function content()
    {
        return [
            'type' => 'input',
            'title' => '内容',
            'field' => 'content',
            'validate' => [
                [
                    'required' => true,
                    'message' => '不能为空',
                ],
            ],
        ];
    }

    public function images()
    {
        return [
            'type' => 'uploadImages',
            'action' => config('thinkAdmin.upload_url'),
            'title' => '评论晒图',
            'field' => 'images',
        ];
    }

    public function show()
    {
        return [
            'type' => 'radio',
            'options' => YesNoEnum::toZhArrayForSelect(),
            'title' => '是否前端显示',
            'field' => 'show',
            'value' => YesNoEnum::getNo()
        ];
    }

    public function rmd()
    {
        return [
            'type' => 'radio',
            'options' => YesNoEnum::toZhArrayForSelect(),
            'title' => '是否推荐',
            'field' => 'rmd',
            'value' => YesNoEnum::getNo()
        ];
    }

    public function inx()
    {
        return [
            'type' => 'number',
            'title' => '排序',
            'field' => 'inx',
            'value' => 100,
        ];
    }

}